home *** CD-ROM | disk | FTP | other *** search
- Path: hermes.is.co.za!news
- From: Wayne Cawood <wcawood@mj.org.za>
- Newsgroups: comp.lang.c++
- Subject: Help:Memory allocation above 64kbytes
- Date: Mon, 15 Jan 1996 16:41:45 +0200
- Organization: Johannesburg Electricity
- Message-ID: <30FA67A9.31CC@mj.org.za>
- NNTP-Posting-Host: 168.89.6.41
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 2.0b5 (Win95; I)
-
- Dear Intellectual!
-
- I am in desperate need of advice on how to combat the problem of
- addressing memory above 64000 bytes. Nothing I do works. I know the
- borland c++ 3.1 compiler should be able to but I am completely confused
- as to why my computer (and others which I have tried on), bomb OUT when
- I attempt to write to this memory.
-
- Here's some code to illustrate the problem.
-
- #inlcude <etc> // If there are any special header files please mention
- them
-
- typedef char buffer[64000];
-
- void main()
- {
- char far *BUF;
-
- BUF = (char far *)new buffer;
-
- }
-
- This allocates the memory, but when I try to write to memory, my system
- shuts down. Please Help! ANYBODY!!!!
- How do I address the EMS,XMS or what ever MS I am supposed to use!
- I have 8megs of extended memory and I can't use it!! How frustrating!!
-
- Thanks in advance!
- Craig Haworth (Games programmer in training)
-